/**
 * The latest applications view.
 *
 * (c) Copyright 2011 Nokia Corporation. All rights reserved.
 */

import QtQuick 1.1
import com.nokia.symbian 1.1

Page {
    id: latestView;

    tools: toolBarLayout;

    BetaView {
        id: latestBetaView;

        anchors {
            fill: parent;
            leftMargin: 10;
            rightMargin: 10;
        }

        Component.onCompleted: {
            getLatest();
        }

        onItemClicked: {
            if (!latestView.pageStack.busy) {
                // Show the details view for the selected beta application
                var detailsPage = latestView.pageStack.push(
                        Qt.resolvedUrl("DetailsView.qml"),
                        { betaId: id });
                detailsPage.fetchDetails(id);
            }
        }
    }
}
